const SEARCH_STATE = {
    isshowPositionPage: false,
    isshowSearchPage: 'transform: translateX(100%)'
}
export default function searchFc(prestate=SEARCH_STATE, action){
    switch(action.type){
        case 'showPos':
            return {...prestate, isshowPositionPage: true}
        case 'hidePos':
            return { ...prestate, isshowPositionPage: false} 

        case 'showSearch':
            return {...prestate, isshowSearchPage: 'transform: translateX(0%)'}  
        case 'hideSearch':
            return { ...prestate, isshowSearchPage: 'transform: translateX(100%)' }    

        default:
            return { ...prestate }
    }
}